﻿using CRM.Presenter;
using CRM.Core.Entities;
using System.Windows.Forms;
using CRM.WinForms.Common;
using CRM.Presenter.Interfaces;
using System.Collections.Generic;

namespace CRM.WinForms.Forms
{
    public partial class Form1 : Form,ICustomer
    {
        public Form1()
        {
            InitializeComponent();
            DelegateToEvents();
        }

        private void DelegateToEvents()
        {
            btnSearch.Click += new CustomerPresenter(this).CustomerSearch;
        }

        public IList<CustomerEntity> BindCustomerData
        {   
            set { gdCustomer.BindToGrid(value); }
        }
    }
}